from tinyshop_mysql.mysql import sql
class cheack:
    def cheack(slef,parm):
        numb = 0
        res = sql().sqlselect('tiny_goods')
        for i in res:
            if i[1] == parm:
                result = sql().sqlcount('tiny_goods',i[1])
                str = result[0]
                numb = str[0]
        return numb
# table = sql().sqlshowtb()
# for i in table:
#     res = sql().sqlselect(i[0])
#     print(i[0],res)
# print(table)
# a = cheack().cheack('T恤')
# print(a)